# -*- coding: utf-8 -*-
"""
---------------------------------------
@File    ：config.py
@Author  ：liyunhui
@Date    ：2024/9/13 下午4:10 
@explain : 文件说明
---------------------------------------
"""

# --------------------------------Redis配置---------------------------------------
redis_host = "8.210.128.35"
redis_port = 6379
redis_db = 0
redis_password = "Ddtj@cpzx!"

# 全部IP
ip_pool_total_ip = "ip_pool:total_ip"

# 目前可用的IP
use_ips = "ip_pool:use_ips"
# IP分类
proxy_classify_key = "ip_pool:classify"
# 代理端口号
proxy_port = 3128

# 所有的分类IP池统一前缀名
total_classify_proxy = "ip_pool:pool"

# --------------------------------服务配置项-------------------------------------------
max_thread_number = 10
settings = {
    "debug": False  # 能自动重启服务
}
options = {
    "port": 12318  # 后续根据需求修改端口号
}

# --------------------------------路由设置---------------------------------------------
ip_update_route = "/api/ip_pool/ip_update"  # ip代理添加或更新
ip_check_route = "/api/ip_pool/ip_check"    # IP检查
ip_call_route = "/api/ip_pool/ip_call"  # 指定机器重拨号
ip_get_route = "/api/ip_pool/ip_get"    # 获取IP的路由

# 根据给定的机器的内网IP将机器分为国内与国外
ip_classify = {
    "is_china": ["10.20.110.50", "10.20.171.126", "192.168.171.145", "10.20.90.38"],  # 国内
    "no_china": ["10.20.174.27", "10.20.174.28", "10.20.68.10", "10.20.72.55", "10.20.68.12", "10.20.72.58"]  # 国外
}
